<!DOCTYPE html>
<html xmlns:th="http://www.thymeleaf.org">
<head>
    <meta charset="UTF-8"/>
    <title th:text="${title}+'-'+${@config.getKey('site.name')}"></title>
    <link rel="stylesheet" th:href="@{/layui/css/layui.css}"/>
    <link rel="stylesheet" th:href="@{/css/css.css}"/>
</head>
<body>
<div style="float: left;width: 960px">

    <fieldset class="layui-elem-field layui-field-title">
        <legend>购买VIP</legend>
    </fieldset>
    <div style="padding-left: 10px">
        VIP到期时间：<font th:text="${session.currentUser.vipTime == null?'无':session.currentUser.vipTimeStr}"></font><br/><br/>
    </div>
    <br>
    <form class="layui-form" style="padding-left: 10px">
        购买时长：
        <input type="radio" name="time" value="10" title="一个月-10元" checked><br>
        <input type="radio" name="time" value="30" title="三个月-30元"><br>
        <input type="radio" name="time" value="60" title="半年-60元"><br>
        <input type="radio" name="time" value="120" title="一年-120元"><br>
        <input type="radio" name="time" value="360" title="三年-360元"><br>
        <input type="radio" name="time" value="888" title="永久-888元">
        <br><br>
        <div class="layui-form-item">
            <div class="layui-input-block">
                <button class="layui-btn" lay-submit lay-filter="formDemo">立即提交</button>
                <button type="reset" class="layui-btn layui-btn-primary">重置</button>
            </div>
        </div>
    </form>


</div>
<script th:src="@{/layui/layui.js}" type="text/javascript"></script>
<script th:src="@{/js/common.js}" type="text/javascript"></script>
<script>
    /*<![CDATA[*/
    layui.use(['element', 'form', 'table'], function () {
        var form = layui.form;
        var element = layui.element; //导航的hover效果、二级菜单等功能，需要依赖element模块

        //监听提交
        form.on('submit(formDemo)', function (data) {
            data.form.action = "/alipay/pay";
            return true;
        });

    });

    /*]]>*/

</script>
</body>
</html>